(function() {
  var docEl = document.documentElement;

  function setRemUnit () {
    var rem = docEl.clientWidth * 14/ 375;
    docEl.style.fontSize = rem + 'px';
  }

  setRemUnit();
  window.addEventListener('resize', setRemUnit,false);
  window.addEventListener('load', setRemUnit, false)
  setTimeout(function () {
    setRemUnit()
    // 防止某些机型怪异现象，异步再调用一次
  }, 333)
})();

